package com.foreverwin.mes.so.model;

import java.io.Serializable;

import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.activerecord.Model;
import java.util.Date;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableField;

import com.baomidou.mybatisplus.annotations.Version;
import com.baomidou.mybatisplus.enums.IdType;

/**
 * <p>
 * 
 * </p>
 *
 * @author Syngna
 * @since 2020-01-14
 */
@TableName("Z_CYCLE_TIME_CONFIG")
public class CycleTimeConfig extends Model<CycleTimeConfig> {

    private static final long serialVersionUID = 1L;

   @TableId(value = "HANDLE", type = IdType.INPUT)
   private String handle;
   @TableField("SITE")
   private String site;
   @TableField("ITEM_BO")
   private String itemBo;
   @TableField("OPERATION_BO")
   private String operationBo;
   @TableField("RESRCE")
   private String resrce;
   @TableField("RESOURCE_TYPE")
   private String resourceType;
   @TableField("CYCLE_TIME")
   private String cycleTime;
   @TableField("NEED_SO_PLAN")
   private String needSoPlan;
   @TableField("STATUS")
   private String status;
   @TableField("CREATED_DATE_TIME")
   private Date createdDateTime;
   @TableField("MODIFIED_DATE_TIME")
   @Version
   private Date modifiedDateTime;
   @TableField("CREATOR")
   private String creator;
   @TableField("UPDATER")
   private String updater;


   public String getHandle() {
      return handle;
   }

   public void setHandle(String handle) {
      this.handle = handle;
   }

   public String getSite() {
      return site;
   }

   public void setSite(String site) {
      this.site = site;
   }

   public String getItemBo() {
      return itemBo;
   }

   public void setItemBo(String itemBo) {
      this.itemBo = itemBo;
   }

   public String getOperationBo() {
      return operationBo;
   }

   public void setOperationBo(String operationBo) {
      this.operationBo = operationBo;
   }

   public String getResrce() {
      return resrce;
   }

   public void setResrce(String resrce) {
      this.resrce = resrce;
   }

   public String getResourceType() {
      return resourceType;
   }

   public void setResourceType(String resourceType) {
      this.resourceType = resourceType;
   }

   public String getCycleTime() {
      return cycleTime;
   }

   public void setCycleTime(String cycleTime) {
      this.cycleTime = cycleTime;
   }

   public String getNeedSoPlan() {
      return needSoPlan;
   }

   public void setNeedSoPlan(String needSoPlan) {
      this.needSoPlan = needSoPlan;
   }

   public String getStatus() {
      return status;
   }

   public void setStatus(String status) {
      this.status = status;
   }

   public Date getCreatedDateTime() {
      return createdDateTime;
   }

   public void setCreatedDateTime(Date createdDateTime) {
      this.createdDateTime = createdDateTime;
   }

   public Date getModifiedDateTime() {
      return modifiedDateTime;
   }

   public void setModifiedDateTime(Date modifiedDateTime) {
      this.modifiedDateTime = modifiedDateTime;
   }

   public String getCreator() {
      return creator;
   }

   public void setCreator(String creator) {
      this.creator = creator;
   }

   public String getUpdater() {
      return updater;
   }

   public void setUpdater(String updater) {
      this.updater = updater;
   }

   public String getKey() {
      String itemBo = this.getItemBo() == null ? "" : this.getItemBo();
      String operationBo = this.getOperationBo() == null ? "" : this.getOperationBo();
      String resrce = this.getResrce() == null ? "" : this.getResrce();
      return "CTBO:" + itemBo + "," + operationBo + "," + resrce;
   }

   public static final String HANDLE = "HANDLE";

   public static final String SITE = "SITE";

   public static final String ITEM_BO = "ITEM_BO";

   public static final String OPERATION_BO = "OPERATION_BO";

   public static final String DEVICE = "DEVICE";

   public static final String RESRCE = "RESRCE";

   public static final String RESOURCE_TYPE = "RESOURCE_TYPE";

   public static final String CYCLE_TIME = "CYCLE_TIME";

   public static final String NEED_SO_PLAN = "NEED_SO_PLAN";

   public static final String STATUS = "STATUS";

   public static final String CREATED_DATE_TIME = "CREATED_DATE_TIME";

   public static final String MODIFIED_DATE_TIME = "MODIFIED_DATE_TIME";

   public static final String CREATOR = "CREATOR";

   public static final String UPDATER = "UPDATER";

   @Override
   protected Serializable pkVal() {
      return this.handle;
   }

   @Override
   public String toString() {
      return "CycleTimeConfig{" +
         "handle = " + handle +
         ", site = " + site +
         ", itemBo = " + itemBo +
         ", operationBo = " + operationBo +
         ", resrce = " + resrce +
         ", resourceType = " + resourceType +
         ", cycleTime = " + cycleTime +
         ", needSoPlan = " + needSoPlan +
         ", status = " + status +
         ", createdDateTime = " + createdDateTime +
         ", modifiedDateTime = " + modifiedDateTime +
         ", creator = " + creator +
         ", updater = " + updater +
         "}";
   }
}